function[y] = minmod(delta_plus, delta_minus)
y = zeros(1,length(delta_plus));
for i = 1:length(delta_plus)
    if ( delta_plus(i) * delta_minus(i) >0)


        y(i) = sign(delta_plus(i)) * min( [abs(delta_plus(i)), abs(delta_minus(i)) ]);

    else
        y(i) = 0;
    end

end